package com.wave.wavesystem.ai.pojo.entity;

import com.mybatisflex.annotation.Column;
import com.mybatisflex.annotation.Id;
import com.mybatisflex.annotation.KeyType;
import com.mybatisflex.annotation.Table;
import com.mybatisflex.core.keygen.KeyGenerators;
import lombok.Builder;
import lombok.Data;

@Data
@Table("rag_post_chunk")
@Builder
public class RagPostChunk {

    @Id(keyType = KeyType.Generator, comment = "主键", value = KeyGenerators.snowFlakeId)
    private Long id;

    @Column(value = "postId", comment = "用户id")
    private Long postId;

    @Column(value = "seq", comment = "段落序号")
    private Integer seq;

    @Column(value = "title", comment = "标题")
    private String title;

    @Column(value = "sliceText", comment = "纯文本切片")
    private String sliceText;

    @Column(value = "tokenNum", comment = "token 数量")
    private Integer tokenNum;

    @Column(value = "embedding", comment = "768 维 float 向量")
    private Byte[] embedding;

    @Column(ignore = true)
    private Double scoreVec;

}